package com.lixh.virtual.api;


import com.lixh.base.BaseResPose;

import java.util.Map;

import io.reactivex.Observable;
import retrofit2.http.FieldMap;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.GET;
import retrofit2.http.HeaderMap;
import retrofit2.http.Headers;
import retrofit2.http.POST;
import retrofit2.http.Path;

/**
 * Created by helin on 2016/10/9 17:09.
 */


public interface ApiService {

    @GET("/rest/2.0/services/cloud_dl?channel=chunlei&web=1&app_id=250528&bdstoken={bdstoken}&logid={}&clienttype=0")
    Observable<BaseResPose<String>> parseMagnetInfo(@Path("bdstoken") String bdstoken, @Path("logid") String logid);

    @GET("/jx/api_jx1.php?do=get_magnet_info&hash={hash}&jxid=miao2)")
    Observable<BaseResPose<String>> getMagnetInfo(@Path("hash") String hash);

    @FormUrlEncoded
    @Headers(
            {"Content-Type", "application/json"
            })
    @POST("/service")
    Observable<BaseResPose<String>> getCxtInfoService(@FieldMap Map<String, String> map);

    @FormUrlEncoded
    @POST
    Observable<BaseResPose<String>> getVideoInfo(@HeaderMap Map<String, String> headers);
}
